aboutsummaryrefslogtreecommitdiff
path: root/pages/api/v2/etc/recent/[page].js
diff options
context:
space:
mode:
authorFactiven <[email protected]>2023-10-24 20:27:32 +0700
committerFactiven <[email protected]>2023-10-24 20:27:32 +0700
commit451e4dffd000169e7113aa3275e4acaf7f1fbbbc (patch)
tree035edf0d05e2f6878be745c326935aba3d821636 /pages/api/v2/etc/recent/[page].js
parentUpdate v4.2.1 (diff)
downloadmoopa-4.2.2.tar.xz
moopa-4.2.2.zip
Update v4.2.2v4.2.2
Diffstat (limited to 'pages/api/v2/etc/recent/[page].js')
-rw-r--r--pages/api/v2/etc/recent/[page].js4
1 files changed, 2 insertions, 2 deletions
diff --git a/pages/api/v2/etc/recent/[page].js b/pages/api/v2/etc/recent/[page].js
index b1bda0f..e21c38e 100644
--- a/pages/api/v2/etc/recent/[page].js
+++ b/pages/api/v2/etc/recent/[page].js
@@ -1,8 +1,8 @@
import { rateLimiterRedis, redis } from "@/lib/redis";
let API_URL;
-API_URL = process.env.API_URI;
-if (API_URL.endsWith("/")) {
+API_URL = process.env.API_URI || null;
+if (API_URL && API_URL.endsWith("/")) {
API_URL = API_URL.slice(0, -1);
}